package com.zy.web.repository;

import com.zy.web.domain.ZyRanks;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface ZyRanksRepository extends JpaRepository<ZyRanks, String>, JpaSpecificationExecutor<ZyRanks> {
    @Query("select id as id ,csry as csry from ZyRanks")
    List<IdAndCsry> findAllIdAndCsz();


    interface IdAndCsry{
        String getId();
        String getCsry();
    }

}
